package com.klikmee.sms.core.base.communicator;

import java.text.MessageFormat;

import com.klikmee.sms.core.model.Provider;

/**
 * Dto class for delivery reports.
 * 
 * @author makcro
 * 
 */
public class DeliveryReport {
	/**
	 * Core Id of the message
	 */
	private Long messageId;
	/**
	 * Provider assigned message id
	 */
	private String providersMessageId;
	
	/**
	 * Resolved mesage status report
	 */
	private Integer status;

	/**
	 * Provider for this delivery report
	 */
	private Provider provider;
	
	public Long getMessageId() {
		return messageId;
	}

	public void setMessageId(Long messageId) {
		this.messageId = messageId;
	}

	public String getProvidersMessageId() {
		return providersMessageId;
	}

	public void setProvidersMessageId(String providersMessageId) {
		this.providersMessageId = providersMessageId;
	}

	public Integer getStatus() {
		return status;
	}

	public void setStatus(Integer status) {
		this.status = status;
	}

	public Provider getProvider() {
		return provider;
	}
	
	public void setProvider(Provider provider) {
		this.provider = provider;
	}

	@Override
	public String toString() {
		// TODO Auto-generated method stub
		return MessageFormat.format("Core id = [{0}], providersId = [{1}], provider [{2}]", this.messageId, this.providersMessageId, this.provider.getName());
	}
	
	
}
